package com.youth.result;

public enum ResultBeanCodeAndMsgEnum {
    SUCCESS_ADD(200, "添加成功"),
    SUCCESS_DELETE(200, "删除成功"),
    SUCCESS_EDIT(200, "修改成功"),
    SUCCESS_QUERY(200, "查询成功"),
    ERROR_ADD(500, "添加失败"),
    ERROR_DELETE(500, "删除失败"),
    ERROR_EDIT(500, "修改失败"),
    ERROR_QUERY(500, "查询失败"),

    NETWORK_BUSY(500, "网络不好，请稍后再试！！！"),
    //    系统错误
    SYSTEM_ERROR(500, "系统错误"),
    //    账号不存在
    ACCOUNT_UNKNOWN(500, "账号不存在"),
    //      账号被禁用
    ACCOUNT_DISABLED(13, "账号被禁用"),
    //    未登录账号
    ACCOUNT_NOT_LOGIN(15, "未登录"),
    //      帐号或者密码错误
    INCORRECT_CREDENTIALS(500, "帐号或者密码错误"),
    //      没有操作权限
    PERMISSION_ERROR(403, "没有操作权限");


    public int code;
    public String msg;

    public int getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }

    ResultBeanCodeAndMsgEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
